package com.project.bean;

import java.util.List;

/**
 * @Author(王思翰)
 * @Description(类的描述)购物车实体类
 * @Date(创建时间) 2021/7/31 13:52
 */
public class ShoppingCarBean {
    /**
     * 购物车id
     */
    private int id;
    /**
     * 商品
     */
    private ProductBean product;
    /**
     * 所属用户
     */
    private UserBean user;
    /**
     * 购买数量
     */
    private int num;

    public ShoppingCarBean() {
    }

    public ShoppingCarBean(ProductBean product, UserBean user, int num) {
        this.product = product;
        this.user = user;
        this.num = num;
    }

    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public ProductBean getProduct() {
        return product;
    }

    public void setProduct(ProductBean product) {
        this.product = product;
    }

    public UserBean getUser() {
        return user;
    }

    public void setUser(UserBean user) {
        this.user = user;
    }

    public int getNum() {
        return num;
    }

    public void setNum(int num) {
        this.num = num;
    }

    @Override
    public String toString() {
        return "ShoppingCarBean{" +
                "id=" + id +
                ", product=" + product +
                ", user=" + user +
                ", num=" + num +
                '}';
    }
}
